Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TopoJSON support #1284

Closed
mourner opened this issue Jan 16, 2013 · 9 comments
Closed

TopoJSON support #1284

mourner opened this issue Jan 16, 2013 · 9 comments
Assignees
Milestone

Comments

@mourner
Copy link
Member

mourner commented Jan 16, 2013

Lets discuss @mbostock's TopoJSON support for Leaflet (either as a plugin or in the core) here. cc @danzel @JasonSanford

@ghost ghost assigned mourner Jan 16, 2013
@JasonSanford
Copy link
Member

Some of @sgillies recent work with converting TopoJSON to GeoJSON with Python will likely help.

@mbostock
Copy link

+1! I'm guessing since Leaflet already supports GeoJSON, the TopoJSON client library, topojson.js should be usable out of the box. In particular, the topojson.object method for converting a TopoJSON object back to a GeoJSON object. Of course it’s always easier if Leaflet can take care of that conversion for you.

The TopoJSON client library also provides a mesh algorithm which is useful for computing boundaries on the fly, such as inter-state boundaries while excluding coastlines. That’s definitely not required to use TopoJSON, but it is quite useful in a number of mapping applications.

Let me know if I can offer any further advice.

@danzel
Copy link
Member

danzel commented Jan 16, 2013

We definitely need a plugin for this if we don't put it in core. Looks cool!

@JasonSanford
Copy link
Member

Yep, seems easy enough. http://bl.ocks.org/4554134

Any strong feelings on core or plugin?

@danzel
Copy link
Member

danzel commented Jan 17, 2013

Feels like a plugin to me

@TheSisb
Copy link

TheSisb commented Feb 6, 2013

I'm new to these parts of Github, but if it has the potential to improve performance as dramatically as suggested then it should be part of the core lib.

@tmcw
Copy link
Contributor

tmcw commented Feb 19, 2013

👍 plugin. If it becomes a 'must-have' it should be core, but TopoJSON is a niche at this point and is a significant amount of code.

@mbostock
Copy link

The minified topojson.object method (which is all you'd need at minimum to convert TopoJSON to GeoJSON) is only 993 bytes, so that’s not a lot of code. But I have no opinion on whether or not to plugin.

@mourner
Copy link
Member Author

mourner commented Apr 9, 2013

I think it's so easy to use the topojson library out of the box with Leaflet that this can be considered done.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants